<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>345教育机构</title>
		<meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1,user-scalable=no">
		<meta name="apple-mobile-web-app-capable" content="yes">
		<meta name="apple-mobile-web-app-status-bar-style" content="black">

		<link rel="stylesheet" href="../../css/simple-line-icons.css">
		<link rel="stylesheet" href="../../css/mui.min.css">
		<link rel="stylesheet" href="../../css/mui-ext.css">
		<style>
			html,
			body {
				background-color: #efeff4;
			}
		</style>
	</head>

	<body>
		<!--<header class="mui-bar mui-bar-nav">
			<a id="back-btn" class="mui-icon mui-icon-left-nav mui-pull-left"></a>
			<h1 class="mui-title">视频</h1>
			<a id="search-btn" class="mui-icon mui-icon-search mui-pull-right"></a>
		</header>-->
		<div class="mui-content">
			<div>
				<ul id="postsFineDat" class="mui-table-view">
					
				</ul>
			</div>
		</div>

		<script src="../../js/mui.min.js"></script>
		<script src="../../js/utils/http.utils.js"></script>
		<script>
			window.onload = function(){
				fun_loadPostsFineVideoData(8, 0);
			}
			
			function fun_loadPostsFineVideoData($psize, $cpage){
				mui.ajax({
					url : $request_url.getPostsFeaVideoLst,
					type : "get",
					dataType : "json",
					headers: {
						"Authorization": $headers_authorization
					},
					data : {
						typeCode : "KCJX"
					},
					success : function(dat){
						if(dat.code == 0){
							var $FineVideoArray = dat.result;
							var $mvidDocHtml = document.getElementById("postsFineDat");
							for(var i = 0; i < $FineVideoArray.length; i ++){
								var $mvideo = $FineVideoArray[i];
								var div =document.createElement('li');
								div.innerHTML = fun_getPostsFineVideoTem($mvideo, i);
								$mvidDocHtml.appendChild(div);
							}
						} else {
							mui.toast(dat.message);
						}
					}, error : function(err){
						mui.toast("......");
					}
				});
			}
				
			function fun_getPostsFineVideoTem($video, $i){
				var $posVidTemHtml = 
					'<li class="mui-table-view-cell mui-media">'
					+	'<a href="course-video.html?vidcode='+ $video.code +'&vidtit='+ $video.title +'" style="display: flex;">'
					+		'<img src="'+ $video.imagePath +'" style="height: 110px; width: 110px;" height="110" width="110">'
					+		'<div class="mui-media-body">'
					+			'<span style="font-size: 15px;">&nbsp;&nbsp;'+ $video.title +'</span><br /><br />'
					+			'<p style="font-size: 13px;" class="mui-ellipsis">&nbsp;&nbsp;'+ $video.description +'</p><br />'
					+			'<p style="font-size: 13px;" class="mui-ellipsis">&nbsp;&nbsp;集数：'+ $video.resourceNum +'集</p>'
					+		'</div>'
					+	'</a>'
					+'</li>';
				return $posVidTemHtml;
			}
		</script>
	</body>

</html>